# coding:utf-8
from sqlalchemy import inspect, Column, Integer, String, SmallInteger, Text, orm

from app.models.base import Base


class User(Base):
    __tablename__ = 'sys_user'

    id = Column(Integer, primary_key=True)
    username = Column(String(32), unique=True, comment="昵称")
    password = Column('password', String(150))
    email = Column(String(32), unique=True, nullable=False, comment="邮箱")
    mobile = Column(String(11))
    gender = Column(SmallInteger, default=1, comment="性别 0=保密 1=男 2=女")
    avatar = Column(String(250), default='', comment="头像")
    intro = Column(Text, default='', comment="简介")
